home *** CD-ROM | disk | FTP | other *** search
/ HPAVC / HPAVC CD-ROM.iso / CCCSCHAT.ZIP / OCOMMAND.PPE (.txt) < prev    next >
PCBoard Programming Language Executable  |  1993-11-25  |  3KB  |  239 lines

  1. ;------------------------------------------------------------------------------
  2. ;                                                   .ss.
  3. ;                                                   `²²'
  4. ;             .,sS$Ss,,s$  .,sS$$$Ss.  .,sS$Ss,,s$ .ss.  .sSs.
  5. ;           .d$$²^°²$$$$'.d$P²°^^²$P'.d$$²^°²$$$$'.$$$' .$$$²Sb,.
  6. ;           $$$'   .$$$' $$$²Sçsµ²' .$$$'   .$$$'.$$$' .$$$'  `$$b.
  7. ;           $$$b,,d$$$' ,$$$b,....,s$$$$b,,d$$$'.$$$;.,$$$'    ;$$$
  8. ;           `²S$$S²²S$$S²°²S$$$$S²°°²S$$$$$$',$$S²°²S$S'.sS$$$P²'
  9. ;                                    .sS²°$$$²²°"'       d²°'
  10. ;                                  .$$²  .$$'
  11. ;                                  $$$.,d$$'
  12. ;                                  `²S$$S²'
  13. ;------------------------------------------------------------------------------
  14. ; P.P.L.X. 2.OO                          (C)1996 - Lone Runner / AEGiS CoRP'96 
  15. ;------------------------------------------------------------------------------
  16. ; PPE 1.OO (plain) - Analysis ON - Postprocessing ON
  17. ;------------------------------------------------------------------------------
  18.  
  19.     Boolean  BOOLEAN001
  20.     Integer  INTEGER001
  21.     Integer  INTEGER002
  22.     Integer  INTEGER003
  23.     Integer  INTEGER004
  24.     Integer  INTEGER005
  25.     String   STRING001
  26.     String   STRING002
  27.     String   STRING003
  28.     String   STRING004
  29.     String   STRING005
  30.     String   STRING006
  31.     String   STRING007
  32.     String   STRING008
  33.     String   STRING009
  34.     String   STRING010
  35.     String   STRING011
  36.     Time     TIME001
  37.     Time     TIME002
  38.     Time     TIME003
  39.  
  40. ;------------------------------------------------------------------------------
  41.  
  42.     TIME001 = Time()
  43.     TIME002 = ReadLine(PCBDat(), 189)
  44.     TIME003 = ReadLine(PCBDat(), 190)
  45.     INTEGER005 = S2I(ReadLine(PPEPath() + "ocommand.cnf", 4), 10)
  46.     STRING011 = Lower(ReadLine(PPEPath() + "ocommand.cnf", 5))
  47.     If (Left(STRING011, 8) == "override") Then
  48.         If (Mid(STRING011, 9, 2) == "on") Then
  49.             BOOLEAN001 = 0
  50.         Else
  51.             BOOLEAN001 = 1
  52.         Endif
  53.     Else
  54.         STRING004 = ReadLine(PPEPath() + "ocommand.cnf", 5)
  55.         If (Right(STRING004, 1) == "\") Then
  56.             STRING004 = STRING004 + "pcboard.sys"
  57.         Else
  58.             STRING004 = STRING004 + "\pcboard.sys"
  59.         Endif
  60.         If (Mid(ReadLine(STRING004, 1), 6, 1) == "0") Then
  61.             BOOLEAN001 = 1
  62.         Else
  63.             BOOLEAN001 = 0
  64.         Endif
  65.     Endif
  66.     STRING006 = Chr(7)
  67.     STRING007 = Chr(13)
  68.     STRING008 = Chr(27) + "["
  69.     STRING009 = STRING008 + "0;0H"
  70.     STRING010 = STRING008 + "K"
  71.     Newline
  72.     InputStr "@X07" + ReadLine(PPEPath() + "ocommand.cnf", 1), STRING005, 0, 60, Mask_Ascii(), 2 + 4096
  73.     If (STRING005 == "") End
  74.     Log "■ SCHAT: " + STRING005, 0
  75.     Newline
  76.     If (((TIME001 >= TIME002) && (TIME001 <= TIME003)) || (CurSec() >= SysopSec())) Then
  77.         If ((CurSec() >= SysopSec()) || !PageStat()) Then
  78.             PageOn
  79.             Newline
  80.             DispStr ReadLine(PPEPath() + "ocommand.cnf", 2)
  81.             STRING001 = ReadLine(PPEPath() + "ocommand.cnf", 3)
  82.             Gosub LABEL004
  83.             For INTEGER003 = 1 To INTEGER005
  84.                 Print "."
  85.                 MPrint STRING006
  86.                 If (BOOLEAN001) Then
  87.                     Delay 14
  88.                     Goto LABEL001
  89.                 Endif
  90.                 For INTEGER004 = 110 To 1760 Step 10
  91.                     Sound INTEGER004
  92.                 Next
  93.                 Sound 0
  94.                 Delay 9
  95.                 :LABEL001
  96.                 STRING003 = KInkey()
  97.                 If (STRING003 == " ") Then
  98.                     STRING001 = ""
  99.                     Gosub LABEL004
  100.                     Call PPEPath() + "schat.ppe"
  101.                     PageOff
  102.                     End
  103.                     Goto LABEL002
  104.                 Endif
  105.                 If (STRING003 == Chr(13)) Then
  106.                     BOOLEAN001 = 1
  107.                 Endif
  108.                 :LABEL002
  109.                 If (Abort()) INTEGER003 = INTEGER005 + 1
  110.                 If (!PageStat()) End
  111.             Next
  112.             STRING001 = ""
  113.             Gosub LABEL004
  114.             If (Abort()) Then
  115.                 ResetDisp
  116.                 Newline
  117.                 End
  118.                 Goto LABEL003
  119.             Endif
  120.             Newline
  121.         Endif
  122.     Endif
  123.     :LABEL003
  124.     PageOn
  125.     DispText 128, 128 + 64
  126.     STRING002 = NoChar()
  127.     PromptStr 571, STRING002, 1, "", 16384 + 64 + 256 + 2 + 8
  128.     If (STRING002 == YesChar()) KbdStuff "C" + STRING007 + "Y" + STRING007
  129.     End
  130.     :LABEL004
  131.     INTEGER001 = GetX()
  132.     INTEGER002 = GetY()
  133.     SPrint STRING009, STRING010
  134.     SPrint STRING001
  135.     SPrint STRING008 + String(INTEGER002) + ";" + String(INTEGER001) + "H"
  136.     Return
  137.  
  138. ;------------------------------------------------------------------------------
  139. ;
  140. ; Usage report (before postprocessing)
  141. ;
  142. ; ■ Statements used :
  143. ;
  144. ;    5       End
  145. ;    21      Goto 
  146. ;    30      Let 
  147. ;    1       Print 
  148. ;    16      If 
  149. ;    1       ResetDisp
  150. ;    1       Log 
  151. ;    1       InputStr 
  152. ;    3       Gosub 
  153. ;    1       Return
  154. ;    1       PromptStr 
  155. ;    2       Delay 
  156. ;    5       Newline
  157. ;    1       DispText 
  158. ;    1       KbdStuff 
  159. ;    1       Call 
  160. ;    1       DispStr 
  161. ;    2       Sound 
  162. ;    3       SPrint 
  163. ;    1       MPrint 
  164. ;    2       PageOn
  165. ;    1       PageOff
  166. ;
  167. ;
  168. ; ■ Functions used :
  169. ;
  170. ;    30      +
  171. ;    8       ==
  172. ;    2       <
  173. ;    3       <=
  174. ;    7       >=
  175. ;    14      !
  176. ;    5       &&
  177. ;    4       ||
  178. ;    1       Lower()
  179. ;    2       Mid()
  180. ;    1       Left()
  181. ;    1       Right()
  182. ;    4       Chr()
  183. ;    2       Abort()
  184. ;    1       Time()
  185. ;    1       NoChar()
  186. ;    1       YesChar()
  187. ;    2       String()
  188. ;    1       Mask_Ascii()
  189. ;    2       PCBDat()
  190. ;    7       PPEPath()
  191. ;    9       ReadLine()
  192. ;    2       SysopSec()
  193. ;    2       CurSec()
  194. ;    1       S2I()
  195. ;    1       GetX()
  196. ;    1       GetY()
  197. ;    1       KInkey()
  198. ;    2       PageStat()
  199. ;
  200. ;------------------------------------------------------------------------------
  201. ;
  202. ; Analysis flags : MCds
  203. ;
  204. ; M - Send text to modem only ■ 4
  205. ;     Some informations are sent only to the modem, not to the local
  206. ;     screen, this is a well known way to make stealth backdoors, Check!
  207. ;     ■ Search for : SENDMODEM, MPRINT, MPRINTLN
  208. ;
  209. ; C - Call child PPE ■ 3
  210. ;     This is usually normal, but may be a tricky way to launch some
  211. ;     sysop-only commands.
  212. ;     ■ Search for : CALL
  213. ;
  214. ; d - Access PCBOARD.DAT ■ 2
  215. ;     Program gets the full pathname to PCBOARD.DAT, this may be usefull
  216. ;     for many PPE so they can find various informations on the system
  217. ;     (system paths, max number of lines in messages, ...) but it may also
  218. ;     be a way to gather vital informations.
  219. ;     ■ Search for : PCBDAT()
  220. ;
  221. ; s - Sysop level access ■ 5
  222. ;     Program is reading the sysop access level, this may be normal
  223. ;     but still it is very suspect. It is the best way to give a user
  224. ;     all priviledges. Check!
  225. ;     ■ Search for : SYSOPSEC()
  226. ;
  227. ;------------------------------------------------------------------------------
  228. ;
  229. ; Postprocessing report
  230. ;
  231. ;    2       For/Next
  232. ;    0       While/EndWhile
  233. ;    10      If/Then or If/Then/Else
  234. ;    0       Select Case
  235. ;
  236. ;------------------------------------------------------------------------------
  237. ;                 AEGiS Corp - Break the routines, code against the machines!
  238. ;------------------------------------------------------------------------------
  239.